blob: 1dca1ece3ecb4ddb4e60dd647b2792b0e93d74cd (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
|
import { auth, post } from "$lib/utils";
import { error, json } from "@sveltejs/kit";
export async function POST({ cookies, request }) {
try {
let body = await request.json();
return json(await post(`/user`, body, auth(cookies)));
} catch (e) {
throw error(500, e.message);
}
}
|